package at.pervasive.mp3player.actions;

import java.net.URL;

import javax.swing.AbstractAction;
import javax.swing.Icon;
import javax.swing.ImageIcon;

import at.pervasive.mp3player.Mp3Player;
import at.pervasive.mp3player.gui.Mp3PlayerFrame;

public abstract class AbstractMp3PlayerAction extends AbstractAction
{

	protected final Mp3Player player;

	public AbstractMp3PlayerAction(Mp3Player player)
	{
		super();
		this.player = player;
	}

	protected final Icon getIcon(String name)
	{
		URL url = Mp3PlayerFrame.class.getResource(name);
		return new ImageIcon(url);
	}

}
